package com.example.printservice.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.pdfbox.pdmodel.PDDocument;
import org.springframework.beans.factory.annotation.Autowired;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value = "attribute", description = "打印属性")
public class DocumentConfiguration {
    /**
     * 文档名称
     */
    @ApiModelProperty("文档名称")
    @NotBlank(message = "文档名称不能为空")
    String fileName;

    /**
     * 指定页码
     */
    @ApiModelProperty("指定页码")
    List<Integer> pageIndex;
    /**
     * 打印份数
     */
//    @NotNull
    @ApiModelProperty("打印份数")
    @Min(value = 1,message = "份数不能少于一份")
    Integer count;

    @TableField
    String token;
}
